package cn.yunhe.entity;

import lombok.Data;

import java.io.Serializable;

/**
 * 车辆实体类表
 * carId ID
 * cardId 车牌号
 * cname 车辆名称
 * cvolume 载重
 * cmileage 里程数
 * state 状态
 * driver 所属司机
 * ddate 发车时间
 */
@Data
public class Car implements Serializable {
    private int carId;
    private String cardId;
    private String cname;
    private int cvolume;
    private double cmileage;
    private int state;
    private Driver driver;
    private String ddate;

    public Car(int carId, String cardId, String cname, int cvolume, double cmileage, Driver driver, String ddate) {
        this.carId = carId;
        this.cardId = cardId;
        this.cname = cname;
        this.cvolume = cvolume;
        this.cmileage = cmileage;
        this.driver = driver;
        this.ddate = ddate;
    }

    public Car(String cardId, String cname, int cvolume, double cmileage, int state, Driver driver, String ddate) {
        this.cardId = cardId;
        this.cname = cname;
        this.cvolume = cvolume;
        this.cmileage = cmileage;
        this.state = state;
        this.driver = driver;
        this.ddate = ddate;
    }

    public Car(int carId, String cardId, String cname, int cvolume, double cmileage, int state, Driver driver, String ddate) {
        this.carId = carId;
        this.cardId = cardId;
        this.cname = cname;
        this.cvolume = cvolume;
        this.cmileage = cmileage;
        this.state = state;
        this.driver = driver;
        this.ddate = ddate;
    }

    public Car(String cname, int cvolume, double cmileage, int state, Driver driver) {
        this.cname = cname;
        this.cvolume = cvolume;
        this.cmileage = cmileage;
        this.state = state;
        this.driver = driver;
    }

    public Car(int carId, String cname, int cvolume, double cmileage, int state, Driver driver) {
        this.carId = carId;
        this.cname = cname;
        this.cvolume = cvolume;
        this.cmileage = cmileage;
        this.state = state;
        this.driver = driver;
    }

    public Car(int carId, String cardId, String cname, int cvolume, double cmileage, int state, Driver driver) {
        this.carId = carId;
        this.cardId = cardId;
        this.cname = cname;
        this.cvolume = cvolume;
        this.cmileage = cmileage;
        this.state = state;
        this.driver = driver;
    }

    public Car(String cardId, String cname, int cvolume, double cmileage, Driver driver, String ddate) {
        this.cardId = cardId;
        this.cname = cname;
        this.cvolume = cvolume;
        this.cmileage = cmileage;
        this.driver = driver;
        this.ddate = ddate;
    }

    public Car() {
    }
}
